home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1999 March / EnigmA AMIGA RUN 35 (1999)(G.R. Edizioni)(IT)[!][issue 1999-03].iso / earcd / -archivi / -recent2 / dmandel.lha / Deluxe Mandelbrot / Scripts / Movie.rexx < prev    next >
OS/2 REXX Batch file  |  1995-11-04  |  2KB  |  85 lines

  1. /* Tiny script to create a mandelbrot movie using ARexx ,
  2.    Deluxe Mandelbrot and DPaint...
  3.    (c) 1995 THOR inc. */
  4.  
  5. /* LF-Character */
  6. lf=x2c('0a')
  7.  
  8. /* Check if DPaint is available */
  9. if show('p','DPAINT.1') then; do
  10.     address DPAINT.1
  11.     screentofront
  12.     address
  13.     screentofront
  14.     /* Lock GUI */
  15.     lockgui
  16.     requestnotify '"Mandelbrot Movie Generator' || lf || '(c) 1995 THOR inc"'
  17.     requestnotify '"Please select the base' || lf || 'range."'
  18.     offverify
  19.     open
  20.     onverify
  21.     menuselected prefs dragbar 'drag'
  22.     if drag=TRUE then
  23.         menu prefs dragbar
  24.     requestnotify '"Please select the start range !"'
  25.     rangeparms 'start'
  26.     requestrange 'start'
  27.     if start.accept=true then; do
  28.         requestresponse '"O.K. to scale ?"' 'answer'
  29.         if answer=TRUE then
  30.             scale max 'start'
  31.  
  32.         requestnotify '"Please select the end range !"'
  33.         rangeparms 'end'
  34.         requestrange 'end'
  35.         if end.accept=true then; do
  36.             requestresponse '"O.K. to scale ?"' 'answer'
  37.             if answer=TRUE then
  38.                 scale max 'end'
  39.             unlockgui
  40.             requestnumber '"Frames Window"' '"Please enter the number of frames:"' 1 1024 32 'frames'
  41.             lockgui
  42.             frames=frames+0
  43.             if length(frames)>0 then; do
  44.                 saveas '"T:Mandel.pic"'
  45.                 address
  46.                 loadpic '"T:Mandel.pic"' chgtofmt nodither
  47.                 setframes frames
  48.                 address        
  49.                 do i=0 to frames-1
  50.                     se=i/(frames-1)
  51.                     sb=1-se
  52.                     rangeparms 'range'
  53.                     range.xmin=sb*start.xmin+se*end.xmin
  54.                     range.ymin=sb*start.ymin+se*end.ymin
  55.                     range.xmax=sb*start.xmax+se*end.xmax
  56.                     range.ymax=sb*start.ymax+se*end.ymax
  57.                     setscreenparms 'range'
  58.                     unlockgui
  59.                     offverify
  60.                     menu project start
  61.                     waitcomplete
  62.                     success 'succ'
  63.                     onverify
  64.                     lockgui
  65.                     if succ='ABORTED' then break
  66.                     saveas '"T:Mandel.pic"'
  67.                     address
  68.                     loadpic '"T:Mandel.pic"'
  69.                     nextframe
  70.                     address
  71.                 end
  72.             end
  73.         end
  74.     end
  75.     requestnotify '"Done !"'
  76.     unlockgui    
  77.     address 
  78.     unlockgui
  79.     address
  80. end; else
  81.     requestnotify '"DPaint is not available !' || lf ||'Please load it first !"'
  82.  
  83.                             
  84.  
  85.